<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>学员基本信息</title>
    <link href="../../layui/css/layui.css" rel="stylesheet">
    <link href="../../static/css/style.css" rel="stylesheet">
    <script src="../../static/js/jquery.min.js"></script>
    <script src="../../static/js/jquery.cookie.js"></script>
    <script src="../../layui/layui.js"></script>
    <script src="../../static/js/base.js"></script>
    <script src="../../static/js/ax.js"></script>
    <!--[if lt IE 9]>
    <script src="../../static/js/html5.js"></script>
    <script src="../../static/js/respond.js"></script>
    <![endif]-->
    <script src="js/constant.js"></script>
</head>
<body>

    <div class="layui-fluid">
        <div class="layui-card">
            <div class="layui-card-header layui-row hearder_title"><h5 class="layui-col-sm7">学员基本信息</h5><div class="layui-col-sm5 xy_btn"><a class="layui-btn layui-btn-primary btn-left"><i class="layui-icon "></i>上一个学员</a><a class="layui-btn layui-btn-primary btn-left">下一个学员</a></div></div>
            <div class="content-wrap">
                <h3 class="title_li">学员基本信息</h3>
                <div class="layui-row">
                    <div class="layui-col-sm12">
                        <table class="layui-table">
                            <tbody>
                            <tr>
                                <td class="bg_h">学员编号</td>
                                <td class="studentNumber"></td>
                                <td class="bg_h">姓名</td>
                                <td class="Name"></td>
                                <td class="bg_h">报名机构</td>
                                <td class="driversName"></td>
                            </tr>
                            <tr>
                                <td class="bg_h">证件类别</td>
                                <td class="sfTypeName"></td>
                                <td class="bg_h">性别</td>
                                <td class="Sex"></td>
                                <td class="bg_h">出生日期</td>
                                <td class="Born"></td>
                            </tr>

                            <tr>
                                <td class="bg_h">证件号码</td>
                                <td class="CardNo"></td>
                                <td class="bg_h">身份证证明有效期止</td>
                                <td class="sfyxq"></td>
                                <td class="bg_h">暂住证编号</td>
                                <td class="stayAddreeNumber"></td>
                            </tr>
                            <tr>
                                <td class="bg_h">学习类别</td>
                                <td class="studyType">xxx</td>
                                <td class="bg_h">申请车型</td>
                                <td class="carName">C1:小型汽车</td>
                                <td class="bg_h">电子信箱</td>
                                <td class="email"></td>
                            </tr>
                            <tr>
                                <td class="bg_h">驾驶人来源</td>
                                <td class="local">xxx</td>
                                <td class="bg_h">手机号码</td>
                                <td class="phone"> </td>
                                <td class="bg_h">国籍</td>
                                <td class="country"></td>
                            </tr>
                            <tr>
                                <td class="bg_h">登记住所</td>
                                <td class="registeredResidence"></td>
                                <td class="bg_h">登记住所行政区划</td>
                                <td class="registeredRegionId"></td>
                                <td class="bg_h">邮政编码</td>
                                <td></td>
                            </tr>
                            <tr>
                                <td class="bg_h">所属辖区</td>
                                <td class="registeredAreaId"> </td>
                                <td class="bg_h">住所详细地址</td>
                                <td class="addressDetailed"></td>
                                <td class="bg_h">住所行政区划</td>
                                <td></td>
                            </tr>
                            <tr>
                                <td class="bg_h">驾校代码</td>
                                <td>xxx</td>
                                <td class="bg_h">驾校名称</td>
                                <td>12245777757</td>
                                <td class="bg_h">所属分所</td>
                                <td>xxxxxxx</td>
                            </tr>
                            <tr>
                                <td class="bg_h">报名日期</td>
                                <td class="registeredTime"> </td>
                                <td class="bg_h">创建时间</td>
                                <td class="created"></td>
                                <td class="bg_h">最后修改时间</td>
                                <td class="updated"></td>
                            </tr>
                            <tr>
                                <td class="bg_h">提交时间</td>
                                <td></td>
                                <td class="bg_h">互联网状态</td>
                                <td class="netStatus"></td>
                                <td class="bg_h">有效期剩余天数</td>
                                <td></td>
                            </tr>
                            <tr>
                                <td class="bg_h">报名来源</td>
                                <td class="registeredSource"></td>
                                <td class="bg_h">学费</td>
                                <td class="registeredTuition"></td>
                                <td class="bg_h">备注</td>
                                <td class="reason"></td>
                            </tr>
                            </tbody>
                        </table>
                    </div>
                </div>
                <h3 class="title_li">报考电子信息</h3>
                <div class="layui-row">
                    <div class="layui-col-xs12">
                        <table class="layui-hide" id="activeListTbale"
                               lay-filter="active"></table>
                        <script type="text/html" id="barDemo">
                            <a class="layui-btn layui-btn-primary layui-btn-xs" lay-event="detail">查看</a>
                            <a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="del">删除</a>
                        </script>
                    </div>
                </div>
                <h3 class="title_li">受理信息</h3>
                <div class="layui-row">
                    <div class="layui-col-sm12">
                        <table class="layui-table">
                            <tbody>
                            <tr>
                                <td class="bg_h">流水号</td>
                                <td>001</td>
                                <td class="bg_h">业务状态</td>
                                <td>啦啦啦</td>
                                <td class="bg_h">原因</td>
                                <td>江北报名点</td>
                            </tr>
                            <tr>
                                <td class="bg_h">受理时间</td>
                                <td>xxxx</td>
                                <td class="bg_h">受理分所</td>
                                <td>xxxxx</td>
                                <td class="bg_h">分所地址</td>
                                <td>XXXXXXXXX</td>
                            </tr>

                            </tbody>
                        </table>
                    </div>
                </div>
            </div>
        </div>



        <div class="layui-card">

            <div class="layui-card-header hearder_title"><h5>学员考试信息</h5></div>

            <div class="content-wrap">
                <table class="layui-hide" id="text2"
                       lay-filter="active"></table>
            </div>

        </div>
        <div class="layui-card">

            <div class="layui-card-header hearder_title"><h5>学员预警信息</h5></div>

            <div class="content-wrap">
                <table class="layui-hide" id="text3"
                       lay-filter="active"></table>
            </div>

        </div>


    </div>

</body>

<script>

     var sid;
    $(function () {
        //初始化
        sid=GetRequest().id;
        initBean(sid);
    });
    layui.use(['table','element'], function(){
        var table = layui.table;

        table.render({
            elem: '#activeListTbale'
            ,url:''
            ,cellMinWidth: 80 //全局定义常规单元格的最小宽度，layui 2.2.1 新增
            ,cols: [[
                {field:'type', title: '文件类型', align: 'center'}
                ,{field:'exporttime', title: '导出时间' , align: 'center'}
                ,{field:'lasttime', title: '最后一次更新时间', align: 'center'}
                ,{field:'sendtime', title: '发送时间', align: 'center'}
                ,{field:'succetime', title: '上传成功时间', align: 'center'},
                ,{field:'state', title: '文件状态', align: 'center'},
                { fixed : 'right', width : 180,title : '操作',toolbar : '#barDemo'} //单元格内容水平居中

            ]]
        });
        table.render({
            elem: '#text2'
            ,url:''
            ,cellMinWidth: 80 //全局定义常规单元格的最小宽度，layui 2.2.1 新增
            ,cols: [[
                {field:'id', title: '序号', align: 'center'}
                ,{field:'classname', title: '考试科目' , align: 'center'}
                ,{field:'testtime', title: '考试时间', align: 'center'}
                ,{field:'testnum', title: '考试次数', align: 'center'}
                ,{field:'textaddress', title: '考试地点', align: 'center'},
                ,{field:'qualified', title: '是否合格', align: 'center'}
            ]]
        });
        table.render({
            elem: '#text3'
            ,url:''
            ,cellMinWidth: 80 //全局定义常规单元格的最小宽度，layui 2.2.1 新增
            ,cols: [[
                {field:'id', title: '序号', align: 'center'}
                ,{field:'stage', title: '所处阶段' , align: 'center'}
                ,{field:'warningtime', title: '预警时间', align: 'center'}
                ,{field:'warningmsg', title: '预警信息', align: 'center'}

            ]]
        });
    });

     function  initBean(id) {

         var  data={studentId:id};
         ax.get({
             url:schoolWebUrl + "/api/student/getStudentById",
             data: data,
             success:function (res) {
                 if (res.code == CODE.OK) {
                     initBeanData(res.data);
                 }
                 if(res.code == CODE.ERROR)
                 {
                     layer.msg(res.message);
                 }
             },
             error : function(request) {
                 layer.msg("修改失败，请联系管理员！");
             }
         });
     }
     function  initBeanData(data){
            console.log(data)
             $(".Name").text(data.name);//姓名
             $(".Sex").text(data.sex);//性别
             $(".Nation").text(data.nation);//民族
             $(".Born").text(data.birthday);//出生日期
             $(".Address").text(data.address);//地址  身份证上的地址
             $(".CardNo").text(data.certificatesNumber);//证件号码
             $(".IssuedAt").text(data.issuedAt);//签发机关
             $(".EffectedDate").text(data.effectedDate);//身份证有效期 开始
             $(".ExpiredDate").text(data.expiredDate);//身份证有效期 结束
             $(".Picture").text("data:image/png;base64," +data.picture);//图片编码
             $(".sfTypeName").text(data.sfTypeName);//证件类型
             $(".country").text(data.country);//国籍
             $(".stu").text(data.studyType);//学习类别
             $(".phone").text(data.phone);//手机号码
             $(".carName").text(data.carName);//准驾车型
             $(".stayAddreeNumber").text(data.stayAddreeNumber);//暂住证编号
             $(".email").text(data.email);//电子邮箱
             $(".registeredAreaId").text(data.registeredAreaId);//所属辖区
             $(".addressDetailed").text(data.addressDetailed);//住所详细地址
             $(".registeredSource").text(data.registeredSource);//报名来源
             $(".registeredRegionId").text(data.registeredRegionId);//登记住所行政区划
             $(".registeredResidence").text(data.registeredResidence);//登记住所详细地址
             $(".local").text(data.local);//来源
             $(".registeredTuition").text(data.registeredTuition);//学费
             $(".studentNumber").text(data.studentNumber);//学员编号
             $(".registeredTime").text(data.registeredTime);//报名日期
             $(".driversName").text(data.driversName);//驾校)结构名称
             $(".referralCode").text(data.referralCode);//推荐码
             $(".reason").text(data.reason);//备注
             $(".driverDriver").text(data.driverDriver);//驾驶证申请表
             $(".visaInterview").text(data.visaInterview);//互联网面签协议
             $(".fingerprint").text(data.fingerprint);//指纹
             $(".idPhoto").text(data.idPhoto);//证件照
             $(".created").text(data.created);//创建时间
             $(".updated").text(data.updated);//最后修改时间
             $(".netStatus").text(data.netStatus);//互联网状态
             $(".sfyxq").text(data.effectedDate+" 至 "+data.expiredDate);//互联网状态

             $(".originalDriverLicense").text(data.originalDriverLicense);//原驾驶证

     }

</script>
</html>